<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:c="http://java.sun.com/jsp/jstl/core"
      xmlns:p="http://primefaces.prime.com.tr/ui"
      xmlns:f="http://java.sun.com/jsf/core">
    <h:body>
        <div class="change_pass">
            <h:panelGroup rendered="${employeeManagedBean.count == 0}" style="padding: 10px 10px;" >There aren't any Schedule Interviews .</h:panelGroup>
            <h:panelGroup rendered="${employeeManagedBean.count != 0}">
                <h3 style="color: #3F8AAC; margin: 5px 0 0 5px;">List Interviews</h3>
                <f:view>
                    <h:form>

                        <h:selectOneMenu style="width: 100px;float: right" valueChangeListener="#{employeeManagedBean.filterSchedule}" >
                            <f:selectItem  itemLabel="day" itemValue="day" ></f:selectItem>
                            <f:selectItem  itemLabel="month" itemValue="month" ></f:selectItem>
                            <f:selectItem  itemLabel="year" itemValue="year"></f:selectItem>
                            <f:ajax event="valueChange" render="outInters" />
                            <f:ajax event="valueChange" render="mes" />
                        </h:selectOneMenu>
                        <h:outputText value="#{employeeManagedBean.me}" id="mes" />
                        <h:dataTable id="outInters" style="text-align: center;" columnClasses="bd_td1,bd_td,bd_td,bd_td,bd_td,bd_td,bd_td,bd_td" cellpadding="3" cellspacing="1" border="0" styleClass="joblist" rowClasses="list_footer_cell" headerClass="list_header_cell" value="#{employeeManagedBean.listInterviews}" var="item">
                            <h:column>
                                <f:facet name="header">
                                    <h:outputText value="Applicant Name"/>
                                </f:facet>
                                <h:commandLink action="#{interviewsManagedBean.showInterviewsDetails(item)}" value="#{item.applicants.applicantName}" >
                                    <f:setPropertyActionListener value="#{item}" target="#{interviewsManagedBean.inter}"  />
                                </h:commandLink>
                            </h:column>
                            <h:column>
                                <f:facet name="header">
                                    <h:outputText value="Vacance Title"/>
                                </f:facet>
                                <h:outputText value="#{item.vacances.vacantyTitle}"/>
                            </h:column>
                            <h:column>
                                <f:facet name="header">
                                    <h:outputText value="Attached Date"/>
                                </f:facet>
                                <h:outputText value="#{item.attachedDate}">
                                    <f:convertDateTime pattern="MM/dd/yyyy" />
                                </h:outputText>
                            </h:column>
                            <h:column>
                                <f:facet name="header">
                                    <h:outputText value="Start Time"/>
                                </f:facet>
                                <h:outputText value="#{item.startTime}"/>
                            </h:column>
                            <h:column>
                                <f:facet name="header">
                                    <h:outputText value="End Time"/>
                                </f:facet>
                                <h:outputText value="#{item.endTime}"/>
                            </h:column>
                            <h:column>
                                <f:facet name="header">
                                    <h:outputText value="Status"/>
                                </f:facet>
                                <h:outputText value="In Process"/>
                            </h:column>
                        </h:dataTable>
                    </h:form>
                </f:view>
            </h:panelGroup>
        </div>
    </h:body>
</html>

